<!--加载中遮罩组件-->
<template >
  <a-spin :spinning="loading" >
    <slot></slot>
  </a-spin>
</template>

<script>
export default {
  name: 'AntSpin',
  data () {
    return {
      loading: false
    }
  },
  created () {
  },
  mounted () {
  },
  beforeDestroy () {
  },
  methods: {
    /**
     * 显示加载中遮罩
     */
    show () {
      this.loading = true
    },
    /**
     * 关闭加载中遮罩
     */
    hide () {
      this.loading = false
    }
  }
}
</script>

<style lang="less" scoped>
 .ant-spin-nested-loading{
  height:100% !important;
  ::v-deep .ant-spin-container{
    height:100% !important;
  }
}

.ant-spin-nested-loading {
  ::v-deep .ant-spin{
    max-height: none;
  }
}
 ::v-deep .ant-spin-dot-item{
   background-color: @primary-color;
 }
</style>
